package com.dragee.modules.work.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.dragee.config.resolver.LongJsonDeserializer;
import com.dragee.config.resolver.LongJsonSerializer;
import com.dragee.modules.work.dto.TeamPerson;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 报名
 * 
 * @author tc
 * @email tc@mail.com
 * @date 2023-04-24 11:32:01
 */
@Data
@TableName("t_apply")
public class ApplyEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId
    @JsonSerialize(using = LongJsonSerializer.class)
    @JsonDeserialize(using = LongJsonDeserializer.class)
    private Long id;

    private String name;

    private String title;

    private String teamId;


    private String competitionId;

    private String competitionName;

    private String leaderIds;

    private String coachIds;

    private String refereeIds;

    private String otherIds;

    private Date joinTime;

    private String singleRoomPresonSum;

    private String standardRoomPersonSum;

    private BigDecimal leaderCost;

    private BigDecimal coachCost;

    private BigDecimal zhuSuCost;

    private BigDecimal entryCost;

    private BigDecimal cost;

    private String mark;

    private String province;

    private String status;

    private String rejectCause;
    // 拼房类型
    private String pinFangType;
    // 发票抬头
    private String invoiceTitle;
    // 税号
    private String invoiceTaxNumber;
    // 电话号码
    private String invoiceTel;
    // 开户行
    private String invoiceBank;
    // 开户行地址
    private String invoiceBankAddress;

    private String invoiceEmail;

    private Integer isImport;
    /**
     * 创建人
     */
    @TableField(fill = FieldFill.INSERT)
    private String createBy;
    /**
     * 创建时间
     */
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;
    /**
     * 修改人
     */
    @TableField(fill = FieldFill.UPDATE)
    private String updateBy;
    /**
     * 修改时间
     */
    @TableField(fill = FieldFill.UPDATE)
    private Date updateTime;
    /**
     * 排序字段
     */
    @TableField(fill = FieldFill.INSERT)
    private Long sort;

    @TableField(exist = false)
    private String teamName;
    @TableField(exist = false)
    private String teamCode;
    @TableField(exist = false)
    private String teamProvince;
    @TableField(exist = false)
    private String teamCity;
    @TableField(exist = false)
    private List<TeamPerson> leaders;
    @TableField(exist = false)
    private List<TeamPerson> coachs;
    @TableField(exist = false)
    private List<TeamPerson> referees;
    @TableField(exist = false)
    private List<TeamPerson> others;
    @TableField(exist = false)
    private String filePayUrl;
    @TableField(exist = false)
    private String filePayName;
    @TableField(exist = false)
    private String fileId;

    @TableField(exist = false)
    private List<ApplyProjectEntity> projects;



    }